#pragma once

#include <QWidget>
#include "ui_devicelist.h"
#include <vector>
#include "device.h"
using namespace std;

class devicelist : public QWidget
{
	Q_OBJECT

public:
	devicelist(QWidget *parent = nullptr);
	~devicelist();

	void data_init();
	void insertTable(Device_Ptr device);
	void freshTable();

private:
	Ui::devicelistClass ui;
signals:
	void datalistFresh();
public slots:
	void onSave();
	void onDelete();
	void onReset();
	void onSearch();
	void onFresh();

public:
	vector<Device_Ptr> m_devicelist;
};
